<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:py="http://genshi.edgewall.org/"
      xmlns:xi="http://www.w3.org/2001/XInclude">
<py:def function="page_title">Login</py:def>
<py:def function="head_info">
<link rel="stylesheet" type="text/css" href="${tg.url('/static/css/login.css')}" />
</py:def>
<py:def function="page_parents"></py:def>

<py:match path="content">
    <p>${message}</p>
    <form action="${previous_url}" method="POST" id="login_form">
        <table>
            <tr>
                <td class="label">
                    <label for="tg_user_name">User Name:</label>
                </td>
                <td class="field">
                    <input type="text" id="tg_user_name" name="tg_user_name"/>
                </td>
            </tr>
            <tr>
                <td class="label">
                    <label for="tg_password">Password:</label>
                </td>
                <td class="field">
                    <input type="password" id="tg_password" name="tg_password"/>
                </td>
            </tr>
            <tr>
                <td colspan="2" class="buttons">
                    <input type="submit" name="tg_login" value="Login"/>
                </td>
            </tr>
        </table>

        <input py:if="forward_url" type="hidden" name="forward_url" value="${forward_url}"/>
            
        <div py:for="name,values in original_parameters.items()" py:strip="1">
        <input py:for="value in isinstance(values, list) and values or [values]"
        type="hidden" name="${name}" value="${value}"/>
        </div>
    </form>
    <p>Don't have an account?  <a href="${tg.url('/user/register')}">Register</a>.</p>
</py:match>

<xi:include href="master.html" />

</html>
